! function() {
	var uploadFiles = {
		getPicture: function(e) {
			var src,
				url = window.URL || window.webkitURL || window.mozURL,
				files = e.target.files;

			if(!files[0]) return null;
			if(url) {
				src = url.createObjectURL(files[0]);
			} else {
				src = e.target.result;
			}
			return src;
		},

		getSrc: function(url, form, fn_opt) {
			ajax().upload(url, form, fn_opt);
		}
	}

	if(typeof thin != 'undefined' && thin.define) {
		thin.define(function(exports) {
			exports("uploadFiles", uploadFiles);
		});
	} else {
		this.uploadFiles = uploadFiles;
	}
}();